package com.u3k.sdk;

import android.util.Base64;
import java.io.ByteArrayInputStream;
import java.io.FileOutputStream;
import java.io.InputStream;

public class c
{
  public static boolean writeStringToFile(String[] paramArrayOfString, String path)
  {
    boolean bool = false;
    ByteArrayInputStream localByteArrayInputStream = null;
    StringBuilder localStringBuilder = new StringBuilder();
    for (int i = 0; i < paramArrayOfString.length; i++) {
      localStringBuilder.append(paramArrayOfString[i]);
    }
    try
    {
      byte[] arrayOfByte1 = Base64.decode(localStringBuilder.toString(), 0);
      FileOutputStream localFileOutputStream = new FileOutputStream(path);
      localByteArrayInputStream = new ByteArrayInputStream(arrayOfByte1);
      if (localByteArrayInputStream != null)
      {
        byte[] arrayOfByte2 = new byte['Ѐ'];
        int j = 0;
        while ((j = localByteArrayInputStream.read(arrayOfByte2)) > 0) {
          localFileOutputStream.write(arrayOfByte2, 0, j);
        }
        localFileOutputStream.close();
        localByteArrayInputStream.close();
      }
      bool = true;
    }
    catch (Exception localException)
    {
      localException.printStackTrace();
      bool = false;
    }
    if (bool) {}
    return bool;
  }
}


